﻿
using Natural.Model;
namespace Natural.Model
{
    public class ActionRequest
    {
        //public Command Command { get; set; }
        public object[] Parameters { get; set; }
        public ActionInfo ActionInfo { get; set; }
    }


    public class ActionContext
    {
        ActionContext Pile = null;
        private InvokeContext _InvokeContext = null;
        public ActionContext(ActionContext pile)
        {
            Pile = pile;
        }
        public ActionContext(InvokeContext invokeContext)
        {
            _InvokeContext = invokeContext;
        }
        public InvokeContext InvokeContext {
            get {
                if (_InvokeContext != null) return _InvokeContext;
                if (Pile != null) return Pile.InvokeContext;
                return null;
            }
        }
        public ActionRequest Request { get; set; }
        public ActionResponse Response { get; set; }
    }


    public class SessionContext
    {
        public string User { get; set; }
    }

    public class InvokeContext
    {
        public SessionContext Session { get; set; }
        public InvokeRequest Request { get; set; }
        public InvokeResponse Response { get; set; }
    }

    
}
